package com.aaa.test1.dao.impl;



import com.aaa.test1.dao.AdminDAO;
import com.aaa.test1.util.DAOUtil;

import java.util.List;
import java.util.Map;

public class AdminDAOImpl implements AdminDAO {
    @Override
    public Map<String, Object> Login(String username, String password) {
        String sql = "select * from t_login where  username = ? and  password = ?";
        List<Map<String, Object>> admin = DAOUtil.query(sql, username, password);

        if (admin.size() > 0) {
            return admin.get(0);
        }

        return null;
    }
}